

<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
<head>
  <meta charset="utf-8">
  
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  
  <title>简单粗暴TensorFlow | A Concise Handbook of TensorFlow &mdash; 简单粗暴TensorFlow 0.3 beta 文档</title>
  

  
  
  
  

  

  
  
    

  

  
  
    <link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
  

  

  
        <link rel="index" title="索引"
              href="genindex.html"/>
        <link rel="search" title="搜索" href="search.html"/>
    <link rel="top" title="简单粗暴TensorFlow 0.3 beta 文档" href="#"/>
        <link rel="next" title="前言" href="zh/preface.html"/> 

  
  <script src="_static/js/modernizr.min.js"></script>

</head>

<body class="wy-body-for-nav" role="document">

   
  <div class="wy-grid-for-nav">

    
    <nav data-toggle="wy-nav-shift" class="wy-nav-side">
      <div class="wy-side-scroll">
        <div class="wy-side-nav-search">
          

          
            <a href="#" class="icon icon-home"> 简单粗暴TensorFlow
          

          
          </a>

          
            
            
              <div class="version">
                0.3
              </div>
            
          

          
<div role="search">
  <form id="rtd-search-form" class="wy-form" action="search.html" method="get">
    <input type="text" name="q" placeholder="Search docs" />
    <input type="hidden" name="check_keywords" value="yes" />
    <input type="hidden" name="area" value="default" />
  </form>
</div>

          
        </div>

        <div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
          
            
            
              
            
            
              <p class="caption"><span class="caption-text">目录</span></p>
<ul>
<li class="toctree-l1"><a class="reference internal" href="zh/preface.html">前言</a></li>
<li class="toctree-l1"><a class="reference internal" href="zh/installation.html">TensorFlow安装</a></li>
<li class="toctree-l1"><a class="reference internal" href="zh/basic.html">TensorFlow基础</a></li>
<li class="toctree-l1"><a class="reference internal" href="zh/models.html">TensorFlow模型</a></li>
<li class="toctree-l1"><a class="reference internal" href="zh/extended.html">TensorFlow扩展</a></li>
<li class="toctree-l1"><a class="reference internal" href="zh/static.html">附录：静态的TensorFlow</a></li>
</ul>
<p class="caption"><span class="caption-text">Contents</span></p>
<ul>
<li class="toctree-l1"><a class="reference internal" href="en/preface.html">Preface</a></li>
<li class="toctree-l1"><a class="reference internal" href="en/installation.html">TensorFlow Installation</a></li>
<li class="toctree-l1"><a class="reference internal" href="en/basic.html">TensorFlow Basic</a></li>
<li class="toctree-l1"><a class="reference internal" href="en/models.html">TensorFlow Models</a></li>
<li class="toctree-l1"><a class="reference internal" href="en/extended.html">TensorFlow Extensions</a></li>
<li class="toctree-l1"><a class="reference internal" href="en/static.html">Appendix: Static TensorFlow</a></li>
</ul>

            
          
        </div>
      </div>
    </nav>

    <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">

      
      <nav class="wy-nav-top" role="navigation" aria-label="top navigation">
        
          <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
          <a href="#">简单粗暴TensorFlow</a>
        
      </nav>


      
      <div class="wy-nav-content">
        <div class="rst-content">
          















<div role="navigation" aria-label="breadcrumbs navigation">

  <ul class="wy-breadcrumbs">
    
      <li><a href="#">Docs</a> &raquo;</li>
        
      <li>简单粗暴TensorFlow | A Concise Handbook of TensorFlow</li>
    
    
      <li class="wy-breadcrumbs-aside">
        
            
            <a href="_sources/index.rst.txt" rel="nofollow"> View page source</a>
          
        
      </li>
    
  </ul>

  
  <hr/>
</div>
          <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
           <div itemprop="articleBody">
            
  <div class="section" id="tensorflow-a-concise-handbook-of-tensorflow">
<h1>简单粗暴TensorFlow | A Concise Handbook of TensorFlow<a class="headerlink" href="#tensorflow-a-concise-handbook-of-tensorflow" title="永久链接至标题">¶</a></h1>
<p><em>基于Eager Execution | Based on Eager Execution</em></p>
<p>本手册是一篇精简的TensorFlow入门指导，基于TensorFlow的Eager Execution（动态图）模式，力图让具备一定机器学习及Python基础的开发者们快速上手TensorFlow。</p>
<p>友情提醒：如果发现阅读中有难以理解的部分，请检查自己对每章的“前置知识”部分是否有清楚的理解。</p>
<p>This handbook is a concise introduction to TensorFlow based on Eager Execution mode, trying to help developers get started with TensorFlow quickly with some basic machine learning and Python knowledge.</p>
<p>Friendly reminder: If you find something difficult to understand in reading, please check the “Prerequisites” part of each chapter.</p>
<table border="1" class="docutils">
<colgroup>
<col width="49%" />
<col width="51%" />
</colgroup>
<tbody valign="top">
<tr class="row-odd"><td><div class="toctree-wrapper first last compound">
<p class="caption"><span class="caption-text">目录</span></p>
<ul>
<li class="toctree-l1"><a class="reference internal" href="zh/preface.html">前言</a></li>
<li class="toctree-l1"><a class="reference internal" href="zh/installation.html">TensorFlow安装</a><ul>
<li class="toctree-l2"><a class="reference internal" href="zh/installation.html#id1">简易安装</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/installation.html#id3">正式安装</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/installation.html#id9">第一个程序</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/installation.html#id12">升级到新版本</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="zh/basic.html">TensorFlow基础</a><ul>
<li class="toctree-l2"><a class="reference internal" href="zh/basic.html#tensorflow-1-1">TensorFlow 1+1</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/basic.html#linear-regression">基础示例：线性回归</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="zh/models.html">TensorFlow模型</a><ul>
<li class="toctree-l2"><a class="reference internal" href="zh/models.html#model-layer">模型（Model）与层（Layer）</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/models.html#mlp">基础示例：多层感知机（MLP）</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/models.html#cnn">卷积神经网络（CNN）</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/models.html#rnn">循环神经网络（RNN）</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/models.html#drl">深度强化学习（DRL）</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/models.html#custom-layer">自定义层 *</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/models.html#graph-execution">Graph Execution模式 *</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="zh/extended.html">TensorFlow扩展</a><ul>
<li class="toctree-l2"><a class="reference internal" href="zh/extended.html#checkpoint">Checkpoint：变量的保存与恢复</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/extended.html#tensorboard">TensorBoard：训练过程可视化</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/extended.html#gpu">GPU的使用与分配</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="zh/static.html">附录：静态的TensorFlow</a><ul>
<li class="toctree-l2"><a class="reference internal" href="zh/static.html#tensorflow-1-1">TensorFlow 1+1</a></li>
<li class="toctree-l2"><a class="reference internal" href="zh/static.html#id3">基础示例：线性回归</a></li>
</ul>
</li>
</ul>
</div>
</td>
<td><div class="toctree-wrapper first last compound">
<p class="caption"><span class="caption-text">Contents</span></p>
<ul>
<li class="toctree-l1"><a class="reference internal" href="en/preface.html">Preface</a></li>
<li class="toctree-l1"><a class="reference internal" href="en/installation.html">TensorFlow Installation</a><ul>
<li class="toctree-l2"><a class="reference internal" href="en/installation.html#simple-installation">Simple Installation</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/installation.html#full-installation">Full Installation</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/installation.html#first-program">First Program</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/installation.html#upgrade-to-a-new-version">Upgrade to A New Version</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="en/basic.html">TensorFlow Basic</a><ul>
<li class="toctree-l2"><a class="reference internal" href="en/basic.html#tensorflow-1-1">TensorFlow 1+1</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/basic.html#a-basic-example-linear-regression">A Basic Example: Linear Regression</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="en/models.html">TensorFlow Models</a><ul>
<li class="toctree-l2"><a class="reference internal" href="en/models.html#models-layers">Models &amp; Layers</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/models.html#a-basic-example-multilayer-perceptrons-mlp">A Basic Example: Multilayer Perceptrons (MLP)</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/models.html#convolutional-neural-networks-cnn">Convolutional Neural Networks (CNN)</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/models.html#recurrent-neural-networks-rnn">Recurrent Neural Networks (RNN)</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/models.html#deep-reinforcement-learning-drl">Deep Reinforcement Learning (DRL)</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/models.html#custom-layers">Custom Layers *</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/models.html#graph-execution-mode">Graph Execution Mode *</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="en/extended.html">TensorFlow Extensions</a><ul>
<li class="toctree-l2"><a class="reference internal" href="en/extended.html#checkpoint-saving-and-restoring-variables">Checkpoint: Saving and Restoring Variables</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/extended.html#tensorboard-visualization-of-the-training-process">TensorBoard: Visualization of the Training Process</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/extended.html#gpu-usage-and-allocation">GPU Usage and Allocation</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="en/static.html">Appendix: Static TensorFlow</a><ul>
<li class="toctree-l2"><a class="reference internal" href="en/static.html#tensorflow-1-1">TensorFlow 1+1</a></li>
<li class="toctree-l2"><a class="reference internal" href="en/static.html#a-basic-example-linear-regression">A Basic Example: Linear Regression</a></li>
</ul>
</li>
</ul>
</div>
</td>
</tr>
</tbody>
</table>
<p>答疑区</p>
<ul class="simple">
<li>（中文）TensorFlow中文社区“简单粗暴TensorFlow”版面： <a class="reference external" href="https://www.tensorflowers.cn/b/48">https://www.tensorflowers.cn/b/48</a> （中文的疑问和建议请来此处，将以中文回答和讨论。欢迎使用中文的开发者们前来TensorFlow中文社区交流讨论）</li>
<li>（英文）https://github.com/snowkylin/TensorFlow-cn/releases （英文的疑问或建议可在GitHub issue中提出，会以英文回答）</li>
</ul>
<p>PDF下载：</p>
<ul class="simple">
<li>中文版：<a class="reference external" href="https://www.tensorflowers.cn/t/6230">https://www.tensorflowers.cn/t/6230</a> （同时也有英文版下载）</li>
<li>英文版：<a class="reference external" href="https://github.com/snowkylin/TensorFlow-cn/releases">https://github.com/snowkylin/TensorFlow-cn/releases</a></li>
</ul>
<p>GitHub: <a class="reference external" href="https://github.com/snowkylin/TensorFlow-cn">https://github.com/snowkylin/TensorFlow-cn</a></p>
<p>Q&amp;A area</p>
<ul class="simple">
<li>(Chinese) TensorFlow Chinese community “A Concise Handbook of TensorFlow” forum: <a class="reference external" href="https://www.tensorflowers.cn/b/48">https://www.tensorflowers.cn/b/48</a></li>
<li>(English) <a class="reference external" href="https://github.com/snowkylin/TensorFlow-cn/issues">https://github.com/snowkylin/TensorFlow-cn/issues</a></li>
</ul>
<p>PDF download:</p>
<ul class="simple">
<li>Chinese version: <a class="reference external" href="https://www.tensorflowers.cn/t/6230">https://www.tensorflowers.cn/t/6230</a></li>
<li>English version: <a class="reference external" href="https://github.com/snowkylin/TensorFlow-cn/releases">https://github.com/snowkylin/TensorFlow-cn/releases</a></li>
</ul>
<p>GitHub: <a class="reference external" href="https://github.com/snowkylin/TensorFlow-cn">https://github.com/snowkylin/TensorFlow-cn</a></p>
<div class="section" id="indices-and-tables">
<h2>Indices and tables<a class="headerlink" href="#indices-and-tables" title="永久链接至标题">¶</a></h2>
<ul class="simple">
<li><a class="reference internal" href="genindex.html"><span class="std std-ref">索引</span></a></li>
<li><a class="reference internal" href="py-modindex.html"><span class="std std-ref">模块索引</span></a></li>
<li><a class="reference internal" href="search.html"><span class="std std-ref">搜索页面</span></a></li>
</ul>
<a href="https://info.flagcounter.com/Hyjs"><img src="https://s05.flagcounter.com/count2/Hyjs/bg_FFFFFF/txt_000000/border_CCCCCC/columns_2/maxflags_16/viewers_0/labels_1/pageviews_1/flags_0/percent_0/" alt="Flag Counter" border="0"></a></div>
</div>


           </div>
           <div class="articleComments">
            
           </div>
          </div>
          <footer>
  
    <div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
      
        <a href="zh/preface.html" class="btn btn-neutral float-right" title="前言" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
      
      
    </div>
  

  <hr/>

  <div role="contentinfo">
    <p>
        &copy; Copyright 2018, Xihan Li（雪麒）.

    </p>
  </div>
  Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/snide/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>. 

</footer>

        </div>
      </div>

    </section>

  </div>
  


  

    <script type="text/javascript">
        var DOCUMENTATION_OPTIONS = {
            URL_ROOT:'./',
            VERSION:'0.3 beta',
            COLLAPSE_INDEX:false,
            FILE_SUFFIX:'.html',
            HAS_SOURCE:  true,
            SOURCELINK_SUFFIX: '.txt'
        };
    </script>
      <script type="text/javascript" src="_static/jquery.js"></script>
      <script type="text/javascript" src="_static/underscore.js"></script>
      <script type="text/javascript" src="_static/doctools.js"></script>
      <script type="text/javascript" src="_static/translations.js"></script>

  

  
  
    <script type="text/javascript" src="_static/js/theme.js"></script>
  

  
  
  <script type="text/javascript">
      jQuery(function () {
          SphinxRtdTheme.StickyNav.enable();
      });
  </script>
   

</body>
</html>